package com.gao.baseboot.singletondiprototype.mi;

import com.gao.baseboot.prototype.PrototypeBean;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Component;

/**
 * @author GaoXi
 * @date 2022/2/21 19:57
 */
@Component
public class MethodInjection {

    /**
     * 获取PrototypeBean通过这个特定的有@LookUp方法的抽象Bean
     */
    @Autowired
    private ProtoTypeBeanManager protoTypeBeanManager;

    public PrototypeBean getPrototypeBean() {
        return protoTypeBeanManager.getPrototypeBean();
    }


}
